﻿
Imports osi.root.connector

Partial Public Class _pointer(Of T)
    Implements IComparable, IComparable(Of _pointer(Of T)), IComparable(Of T)

    Public Function CompareTo(ByVal obj As Object) As Int32 Implements IComparable.CompareTo
        Return CompareTo(cast(Of _pointer(Of T))(obj, False))
    End Function

    Public Function CompareTo(ByVal that As _pointer(Of T)) As Int32 _
                             Implements IComparable(Of _pointer(Of T)).CompareTo
        Return CompareTo(+that)
    End Function

    Public Function CompareTo(ByVal that As T) As Int32 Implements IComparable(Of T).CompareTo
        Return compare([get](), that)
    End Function
End Class
